/* Filename: getenv.c
 * Description: 获取环境变量值，查看printenv
 * Last modified: humble 20200319 19:32
 */
#include <stdio.h>
#include <stdlib.h>

static void usage(void);

int main(int argc, char **argv) {
    if(argc != 1){ fprintf(stderr, "argc !=1"); usage(); exit(1); }
    puts(getenv("PWD")); //当前目录
    return 0;
}

static void usage(void)
{
#define USAGE "Usage:\n\
  Helloworld\n"
    printf(USAGE);
}
